package com.example.sys.speciality.dao;

import com.example.core.dao.BaseDao;
import com.example.sys.speciality.po.SysSpeciality;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface SysSpecialityDao extends BaseDao<SysSpeciality> {

    @Select("select * from sys_speciality where user_id =#{userId}")
    public List<SysSpeciality> getSpecialityByUserId(@Param("userId") String userId);

    @Delete("delete from sys_speciality where user_id =#{userId}")
    public void clearByUserId(@Param("userId") String userId);
}
